#ifndef ONT_INCLUDE_ONT__ERROR_H_
#define ONT_INCLUDE_ONT__ERROR_H_


#define  ONT_ERR_OK                         0
#define  ONT_ERR_BADPARAM                   -1
#define  ONT_ERR_SOCKET_OP_FAIL             -2
#define  ONT_ERR_SOCKET_ISCONN              -3
#define  ONT_ERR_SOCKET_INPROGRESS          -4
#define  ONT_ERR_SOCKET_NOTSUPPORTED        -5
#define  ONT_ERR_SOCKET_SND_TIMEOUT         -6
#define  ONT_ERR_SOCKET_RCV_TIMEOUT         -7

#define  ONT_ERR_CREATE_DS_FAILED           -8
#define  ONT_ERR_STATUS_READFAIL            -9
#define  ONT_ERR_STATUS_WRITEFAIL           -10

#define  ONT_ERR_INTERNAL                   -11
#define  ONT_ERR_NOMEM                      -12
#define  ONT_ERR_ENC_FAIL                   -13
#define  ONT_ERR_DEC_FAIL                   -14




typedef enum _ONT_PLATFORM_CODE_t {
	ONT_PF_CODE_SUCCESS = 0,
	ONT_PF_CODE_REGISTERED = 1,
	ONT_PF_CODE_CHANNEL_NOTEXIST = 2,
	ONT_PF_CODE_SERVER_ERROR = 3,
	ONT_PF_CODE_REGISTER_AUTH_FAIL = 4,
	ONT_PF_CODE_REGISTER_INVALID_PARAM = 5,
	ONT_PF_CODE_REGISTER_PARAM_LESS = 6,
	ONT_PF_CODE_REGISTER_SYSTEM_ERROR = 7,
	ONT_PF_CODE_REGISTER_UNKNOWN_ERROR = 8,
	ONT_PF_CODE_CONNECT_AUTH_TOKEN_EXPIRED = 9,
	ONT_PF_CODE_CONNECT_AUTH_WRONG_TOKEN = 10,
	ONT_PF_CODE_CONNECT_AUTH_WRONG_IP = 11,
	ONT_PF_CODE_DEVICE_AUTH_CODE_UPDATE = 12,
	ONT_PF_CODE_DEVICE_AUTH_FAIL = 13,
	ONT_PF_CODE_DEVICE_CHANNEL_FULL = 14,
	ONT_PF_CODE_DEVICE_CHANNELNUM_ERR = 15
} ONT_PLATFORM_CODE_t;

typedef enum _ONT_REPONSE_CODE_t {
	ONT_RET_SUCCESS = 0,
	ONT_RET_CHANNEL_NOTEXIST = 1,
	ONT_RET_CHANNEL_FILE_NOTEXIST = 2,
	ONT_RET_CHANNEL_RTMP_CONNECT_FAIL = 3,
	ONT_RET_NOT_SUPPORT = 4,
	ONT_RET_CMD_ERROR = 5,
	ONT_RET_CHANNEL_ALREADY_START = 6,
	ONT_RET_LIVE_PLAY_ERROR = 7
} ONT_REPONSE_CODE_t;


#endif /* ONT_INCLUDE_ONT__ERROR_H_ */
